#! /bin/bash

for ((i=0;i<500;i+=18))
do
	file=franklin/bench$i.batch
	echo "#PBS -l nodes=1:ppn=2,walltime=00:30:00" > $file
	echo "#PBS -N sw$i" >> $file
	echo "#PBS -o results/sw$i.out">> $file
	echo "#PBS -e results/sw$i.err">> $file
	echo "#PBS -q batch">> $file
	echo "#PBS -S /bin/sh">> $file

	echo "">> $file
	echo "cd \$PBS_O_WORKDIR">> $file
	echo "./sw_bench $i" >> $file
done

